pub fn dp_rec_mc(amount: u32) -> u32 {
    // 定义可用的纸币面值
    let coins = [1, 2, 5, 10, 20, 30, 50, 100];
    
    // 初始化dp数组，dp[i]表示凑成金额i所需的最少纸币数
    let mut dp = vec![u32::MAX; (amount + 1) as usize];
    dp[0] = 0; // 金额为0时需要0张纸币

    // 动态规划计算
    for i in 1..=amount as usize {
        for &coin in &coins {
            if i >= coin as usize {
                dp[i] = dp[i].min(dp[i - coin as usize] + 1);
            }
        }
    }

    // 返回结果，如果无法找零返回0
    if dp[amount as usize] == u32::MAX {
        0
    } else {
        dp[amount as usize]
    }
}